//
//  HHPropertyTableViewCell.h
//  HHBroker
//
//  Created by He Wei on 9/19/15.
//  Copyright © 2015 harry. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "HHPropertyInfoModel.h"

@class HHPropertyTableViewCell;
@protocol HHPropertyTableViewCellDelegate <NSObject>

- (void)HHPropertyTableViewCell:(HHPropertyTableViewCell *)cell selectNextResponseWithIndexPath:(NSIndexPath *)indexPath;

- (void)HHPropertyTableViewCell:(HHPropertyTableViewCell *)cell selectLastResponseWithIndexPath :(NSIndexPath *)indexPath;

- (void)HHPropertyTableViewCell:(HHPropertyTableViewCell *)cell completeResponseWithIndexPath :(NSIndexPath *)indexPath;

/**
 *  @param cell  当前响应的cell
 *  @param indexPath  当前响应的cell在table中的indexPath
 *  @param type    0为键盘   1为picker
 *  @param tag     若为picker, tag 为picker数据源的标记
 */
- (void)HHPropertyTableViewCell:(HHPropertyTableViewCell *)cell didBeginEditingWithIndexPath:(NSIndexPath *)indexPath type:(NSInteger)type tag:(NSInteger)tag;

@end


@interface HHPropertyTableViewCell : UITableViewCell

@property (nonatomic, weak) IBOutlet UILabel *titleLabel;
@property (nonatomic, weak) IBOutlet UITextField *infoTextField;

@property (nonatomic, weak) UIView *inputView;
@property (nonatomic, weak) id<HHPropertyTableViewCellDelegate> delegate;

@property (nonatomic, assign) BOOL isFirst;
@property (nonatomic, assign) BOOL isLast;
@property (nonatomic, strong) NSIndexPath *indexPath;
@property (nonatomic, strong) HHPropertyInfoModel *model;
















@end
